import http from './http';

export default {
  /**
   * @description: 获取类目列表
   * @param {type}
   * @return:
   */
  getCategoryList(data) {
    return http.get(`/mall/web/product/v1/category/categories`).exec();
  },

  /**
   * @description: 新增类目列表
   * @param {type}
   * @return:
   */
  addCategoryList(data) {
    return http.post(`/mall/web/product/v1/category/add`, data).exec();
  },

  /**
   * @description: 修改类别信息
   * @param {type}
   * @return:
   */
  setCategory(data) {
    return http.post(`/mall/web/product/v1/category/modify`, data).exec();
  },

  /**
   * 删除分类
   * @param {*} data
   * @returns
   */
  deleteCategory(data) {
    return http.post(`/mall/web/product/v1/category/delete`, data).exec();
  },
};
